What could make GetCursorPos return incorrect coordinates of {0,0} ?
Posted
by Dave Moore
on Stack Overflow
See other posts from Stack Overflow
or by Dave Moore
Published on 2010-04-15T18:41:55Z
Indexed on
2010/04/15
18:43 UTC
Read the original article
Hit count: 380
We are seeing bad behavior in an application when it runs on Server 2008 (not R2). This is a WinForms application, and Control.MousePosition is returning {0,0} no matter where the mouse is on the screen... Control.MousePosition just makes a P/Invoke call to Win32 api GetCursorPos().
There is a control in our library that calls SetWindowsHookEx to hook WH_CALLWNDPROCRET for our entire process. I'm suspicious of this code, but tracing statements show that we're getting in + out of that hook cleanly.
What else should I be looking for?
Thanks, Dave
© Stack Overflow or respective owner